package com.dwxt.community.dao;

import com.dwxt.community.entity.*;
import com.dwxt.community.entity.vo.*;
import org.apache.ibatis.annotations.*;

import java.util.*;

public interface InformationMapper {
    int countByExample(InformationExample example);

    int deleteByExample(InformationExample example);

    int deleteByPrimaryKey(String id);

    int insert(InformationWithBLOBs record);

    int insertSelective(InformationWithBLOBs record);

    List<InformationWithBLOBs> selectByExampleWithBLOBs(InformationExample example);

    List<Information> selectByExample(InformationExample example);

    InformationWithBLOBs selectByPrimaryKey(String id);

    int updateByExampleSelective(@Param("record") InformationWithBLOBs record, @Param("example") InformationExample example);

    int updateByExampleWithBLOBs(@Param("record") InformationWithBLOBs record, @Param("example") InformationExample example);

    int updateByExample(@Param("record") Information record, @Param("example") InformationExample example);

    int updateByPrimaryKeySelective(InformationWithBLOBs record);

    int updateByPrimaryKeyWithBLOBs(InformationWithBLOBs record);

    int updateByPrimaryKey(Information record);

    List<InformationVo> selectAll(@Param("type") String type,
                                  @Param("name") String name,
                                  @Param("release") Integer release,
                                  @Param("notAdLocation") boolean notAdLocation,
                                  @Param("recommend") Integer recommend
    );

    InformationVo selectById(String id);

    List<InfomationLocationVo> getByLocation();

    List<InfomationLocationVo> selectViewPaper();

    int delLocation(String id);

    Information selectByAdLocationId(String adLocationId);


    List<InformationVo> selectAllDesk(@Param("type")String type,@Param("recommend") Integer recommend);

    List<InfomationLocationVo>  selectAdInfo();

    Integer countByCreateTime(String date);

    List<Information> selectByLocationType(Integer type);
}